#ifndef TEXTRENDERER_H
#define TEXTRENDERER_H

#include "components/Renderer.h"
#include "types/Font.h"
#include "types/Color.h"

namespace SolidityEngine{

class TextRenderer : public Renderer
{
    public:
        TextRenderer(RenderTarget target = Renderer::RT_SCREEN);
        virtual ~TextRenderer();

        void SetFont(Font* font);

        Font* GetFont();

        std::string& Label() {return _text;};
        std::string Label() const {return _text;};

        Vector2D& Pivot(){return _pivot;};
        Vector2D Pivot() const {return _pivot;};

    protected:
        Font* _font;    //the font for this text
        Vector2D _pivot;    //the glyph pivot
        std::string _text;  //the actual text string

    private:
        virtual void _Render(SDL_Surface* surface);
        virtual TextRenderer* _Clone();
};

}

#endif // TEXTRENDERER_H
